﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ShortLink.Common.Enums
{
    public enum BizCodeEnum
    {
        // 短链分组
        [Description("分组名重复")] GROUP_REPEAT = 23001,
        [Description("分组名操作失败")] GROUP_OPER_FAIL = 23503,
        [Description("分组不存在")] GROUP_NOT_EXIST = 23404,

        // 验证码
        [Description("接收号码不合规")] CODE_TO_ERROR = 240001,
        [Description("验证码发送过快")] CODE_LIMITED = 240002,
        [Description("验证码错误")] CODE_ERROR = 240003,
        [Description("图形验证码错误")] CODE_CAPTCHA_ERROR = 240101,

        // 账号
        [Description("账号已经存在")] ACCOUNT_REPEAT = 250001,
        [Description("账号不存在")] ACCOUNT_UNREGISTER = 250002,
        [Description("账号或者密码错误")] ACCOUNT_PWD_ERROR = 250003,
        [Description("账号未登录")] ACCOUNT_UNLOGIN = 250004,

        // 短链
        [Description("短链不存在")] SHORT_LINK_NOT_EXIST = 260404,

        // 订单
        [Description("创建订单-验价失败")] ORDER_CONFIRM_PRICE_FAIL = 280002,
        [Description("订单恶意-重复提交")] ORDER_CONFIRM_REPEAT = 280008,
        [Description("订单令牌缺少")] ORDER_CONFIRM_TOKEN_EQUAL_FAIL = 280009,
        [Description("订单不存在")] ORDER_CONFIRM_NOT_EXIST = 280010,

        // 支付
        [Description("创建支付订单失败")] PAY_ORDER_FAIL = 300001,
        [Description("支付订单回调验证签失败")] PAY_ORDER_CALLBACK_SIGN_FAIL = 300002,
        [Description("支付宝回调更新订单失败")] PAY_ORDER_CALLBACK_NOT_SUCCESS = 300003,
        [Description("订单不存在")] PAY_ORDER_NOT_EXIST = 300005,
        [Description("订单状态不正常")] PAY_ORDER_STATE_ERROR = 300006,
        [Description("订单支付超时")] PAY_ORDER_PAY_TIMEOUT = 300007,

        // 流控操作
        [Description("限流控制")] CONTROL_FLOW = 500101,
        [Description("降级控制")] CONTROL_DEGRADE = 500201,
        [Description("认证控制")] CONTROL_AUTH = 500301,

        // 流量包操作
        [Description("免费流量包不存在，联系客服")] TRAFFIC_FREE_NOT_EXIST = 600101,
        [Description("流量不足，扣减失败")] TRAFFIC_REDUCE_FAIL = 600102,
        [Description("流量包数据异常，用户无流量包")] TRAFFIC_EXCEPTION = 600103,

        // 通用操作码
        [Description("重复操作")] OPS_REPEAT = 110001,
        [Description("网络地址错误")] OPS_NETWORK_ADDRESS_ERROR = 110002,

        // 文件相关
        [Description("用户头像文件上传失败")] FILE_UPLOAD_USER_IMG_FAIL = 700101
    }

  
}
